package com.xiao.springaopdemo1.annnotation;


import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.springframework.core.annotation.Order;
import org.springframework.stereotype.Component;



@Component
@Aspect //将当前组件标识为切面
@Order(2)//设置优先级 数值越小优先级越高
public class ValidateAspectsOne {


    //使用同一个pointcut()
    //@Before("com.xiao.springaopdemo1.loggAspects.Pointcut()")
    @Before("execution(* com.xiao.springaopdemo1.annnotation.CalculatorOneImpl.*(..))")
    public  void  Method(){
        System.out.println("前置通知1");
    }
}
